package com.jader.adapter;

import java.util.ArrayList;
import java.util.List;

import com.jader.beans.LunTan_All_PinLun_Bens;

import android.content.Context;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import android.widget.TextView;

public class MyAdapter_ALL_PingLun extends BaseAdapter {
	public List<LunTan_All_PinLun_Bens> list = new ArrayList<LunTan_All_PinLun_Bens>();
	// 接收上下文参数，以便了解是哪个activity在调用
	Context context;
	// 用来初始化布局文件，可以把一个xml布局转换为对应的android对象view
	LayoutInflater mInflater;
	ViewHolder4 viewHolder;

	public MyAdapter_ALL_PingLun(List<LunTan_All_PinLun_Bens> list,
			Context context) {
		super();
		this.list = list;
		this.context = context;
		mInflater = LayoutInflater.from(context);
	}

	public void onDateChange(List<LunTan_All_PinLun_Bens> list) {
		this.list = list;
		this.notifyDataSetChanged();
	}

	@Override
	public int getCount() {
		// TODO Auto-generated method stub
		return list.size();
	}

	@Override
	public Object getItem(int position) {
		// TODO Auto-generated method stub
		return list.get(position);
	}

	@Override
	public long getItemId(int position) {
		// TODO Auto-generated method stub
		return position;
	}

	@Override
	public View getView(int position, View convertView, ViewGroup parent) {
		// TODO Auto-generated method stub
		return null;
	}

	class ViewHolder4 {
		TextView pinglunzheTextView, pinglunneirongTextView;
	}

}
